<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
    <title>Index</title>
    <link rel="stylesheet" href="static/css/reset.css">
    <link rel="stylesheet" href="static/css/c-global.css">
    <style type="text/css">
        body {
            background-color: #f5f5f5;
        }
    </style>
</head>
<body>
<script src="static/other/layui/layui.all.js"></script>
<script src="static/other/layer/layer.js"></script>
<script src="static/other/jquery-1.7.1/jquery-1.7.1.min.js"></script>
    <div class="wrap">
        <div class="c-input-file-wrap">
            <input id="file-upload" type="file">
        </div>
    </div>

    <script src="static/js/global_jq.js"></script>
    <script src="static/js/distpickerData.js"></script>
    <script src="static/js/c.js"></script>
    <script type="text/javascript">

    </script>
    <script type="text/javascript">
        $(function () {

            $('#file-upload').change(function () {
                var self = $(this);
                var file = self[0].files[0];
                var reader = new FileReader();
                reader.readAsDataURL(file);
                reader.onload = function (e) {
                    var url = "url(" + e.target.result + ") no-repeat";
                    $('.c-input-file-wrap').css('background', url).css('backgroundSize', " 100% 100%");
                };
            });
        });
    </script>
</body>
</html>